package com.srxz.mobilepharmacy.controller;

import com.srxz.mobilepharmacy.service.HospitalService;
import com.srxz.mobilepharmacy.util.back.BackMessage;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Repository;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

@RestController
@RequestMapping("/mphs/hospital")
public class HospitalController {
    @Autowired
    private HospitalService hospitalService;

    @GetMapping("/findall")
    public BackMessage findhospitals(){
        return hospitalService.findhospitals();
    }
}
